package com.dyh.quickdemo.GoodsRules;

import java.util.function.Function;

/*
@Author=Joey Wheeler
@Date=2021/3/4 16:33
*/
public class FunctionChain {



    public static void main(String[] args) {


        System.out.println(
                (( Function<String,Integer>) String::length)
                        .andThen(e->e+"1")
                        .andThen(String::length)
                        .apply("11")
                );

    }

    /*
            Function<String,Integer> start = String::length;

        System.out.println(start.andThen(e->e+"1").andThen(String::length).apply("11"));
    */
}
